<%@ taglib prefix="sf" uri="http://www.springframework.org/tags/form" %>
<%--
  Created by IntelliJ IDEA.
  User: 15c
  Date: 2017/6/5
  Time: 22:31
  To change this template use File | Settings | File Templates.
--%>
<%@ page contentType="text/html;charset=UTF-8" language="java" %>
<html>
<head>
    <title>update_grade</title>
</head>
<body>
<jsp:include page="head.jsp"/>
<div style="height: auto;width: 100%;text-align: center">
  <div style="margin:5% auto">
    <h2>学生成绩更新</h2>
    <sf:form action="${pageContext.request.contextPath}/students/update_grade" method="post">
      <p style="font-weight: bold">学号:<input type="text" name="sno" value="${student.sc1.sno}" readOnly="true"
                                             style="margin-top: 2%" placeholder="${student.sc1.sno}"/></p>

      <p style="font-weight: bold">姓名:<input type="text" name="sname" value="${student.sname}"  readOnly="true"
                                             style="margin-top: 1%" placeholder="${student.sname}"/></p>


      <p style="font-weight: bold">课程号:<input type="text" name="cno" value="${student.sc1.cno}"  readOnly="true"
                                             style="margin-top: 1%" placeholder="${student.sc1.cno}"/></p>

      <p style="font-weight: bold">课程名:<input type="text" name="cname" value="${student.course1.cname}"  readOnly="true"
                                             style="margin-top: 1%" placeholder="${student.course1.cname}"/></p>

      <p style="font-weight: bold">成绩:<input type="text" name="grade" value="${student.sc1.grade}"
                                               style="margin-top: 1%" placeholder="${student.sc1.grade}"/></p>

      <input type="submit" value="提交" style="border:3px solid #ccc;background:#cccccc;margin-top: 1%">
      <a href="${pageContext.request.contextPath}/students/view_results?sno=${student.sc1.sno}"><input type="button" value="取消"
                                                                style="border:3px solid #ccc;background:#cccccc;margin-left: 2%;margin-top: 1%"></a>
    </sf:form>
  </div>
</div>
</body>
</html>
